﻿

<include file="Public/header"/>
<link href="__HOME_CSS__/5a6c2cee82cedcc596a41acd.css" rel="stylesheet">
<div> 
    <div class="ty-banner-1">
        <a href="article/khjz.html" title="博森护栏网的成绩源自于上千家客户的信任"> <img alt="博森护栏网的成绩源自于上千家客户的信任" src="picture/357a42e529aa4c90af6d1d56da535f8f_62.jpg" title="博森护栏网的成绩源自于上千家客户的信任"> </a> 
    </div> 
</div>
<include file="Public/keyword"/>

<div class="blk-main"> 
    <div class="blk plc"> 
        <div class="p12-curmbs-1" navcrumbs=""> 
            <b> 您的位置: </b> 
            <a href=""> 首页 </a> 
            <span> &gt; </span> 
            <i class=""> <a href="Tools/leaveword.html"> 在线留言 </a>  </i> 
        </div> 
    </div> 
	<div class="clear"></div> 
    <div class="blk-md"> 
        <div class="r1-orderform-1 blk"> 
            <div class="p4-order-form-1"> 
            	<h3 class="p4-titlel-1 tit-md">在线留言<span></span><em></em></h3> 
                <div class="p4-order-form-1-con"> 
                    <div class="form-horizontal" id="intentionalOrderFormId" name="intentionalOrderForm">
                    <input name="vcenter" type="hidden" value="http://centern.nsw99.com//center/intentionalOrder/add"> 
                    <input name="projId" type="hidden" value="20180110100453022258"> 
                    <input name="formId" type="hidden" value="5a5574cc82ce68f4f71c6f23"> 
                    <ul class="findrow"> 
                        <li>
                            <label><b>*</b><span class="row-hd">姓名：</span></label>
                            <input class="inputs" maxlength="10" id="username" name="username" placeholder="请填写您的姓名，以便于我方给您回复" required title="姓名" type="text">
                            <p class="info"></p>
                        </li>
                        <li>
                            <label><b>*</b><span class="row-hd">手机号码：</span></label>
                            <input class="inputs" maxlength="11" id="tel"  name="tel" pattern="phone" placeholder="请填写您的手机号码，填写后我司将第一时间与您通过电话取得联系" required title="手机号码" type="text">
                            <p class="info"></p>
                        </li>
                        <li>
                            <label><b>*</b><span class="row-hd">电子邮件：</span></label>
                            <input class="inputs" maxlength="50" id="mail" name="mail" pattern="email" placeholder="请填写您的电子邮件，填写后我司将通过电子邮件给您回复" required title="电子邮件" type="text">
                            <p class="info"></p>
                        </li>
                        <li class="p4-order-form-1-t1">
                            <label><span class="row-hd">留言内容：</span></label>
                            <textarea maxlength="300" id="content" name="content" placeholder="请真实详尽填写留言内容" title="留言内容"></textarea>
                            <p class="info"></p>
                        </li>
                        <li class="p4-order-form-1-t3">
                            <input class="p4-order-form-1-b1" type="button" id="sub_message" value="提交">
                            <input class="p4-order-form-1-b2 reset" type="button" value="清除">
                        </li> 
                        <p class="timenum"></p> 
                    </ul> 
                    </div>
                    <p class="timeinterval" style="display:none;">30</p> 
                    <p class="isvalidate" style="display:none;">true</p> 
                </div> 
            </div>
        </div> 
    </div> 
	<div class="clear"></div> 
</div>

<include file="Public/footer"/>
<include file="Public/toolbar"/>
<script src="__HOME_JS__/5a6c2cee82cedcc596a41acd.js" type="text/javascript"></script>
<script src="__HOME_JS__/layer/layer.js"></script>
<script>
    $("#sub_message").click(function () {
        var username = $("#username").val();
        var tel = $("#tel").val();
        var mail = $("#mail").val();
        var content = $("#content").val();
        var myreg = /^((\d{3}-\d{8}|\d{4}-\d{7,8})|(1[3|5|7|8][0-9]{9}))$/;
        if (username=="") {
            layer.msg('姓名不能为空');
            return false;
        }
        if (tel=="") {
            layer.msg('手机号码不能为空');
            return false;
        }
        if(!myreg.test(tel)){
            layer.msg("手机号格式不正确");
            return false;
        }
        else {
            $.ajax({
                type: "post",
                url: "/application.html",
                data: { username: username, tel: tel, content: content , mail: mail},
                dataType:"json",
                success: function (data) {
                    if (data.code == 200) {
                        layer.msg('留言成功', {
                            time: 1000, //1s后自动关闭
                            shade: 0.1
                        },function () {
                            window.location.reload();
                        })
                    }else{
                        layer.msg(data.msg);
                    }
                },
                error: function () {
                    console.log("Ajax Request Error");
                }
            });
        }
    });
</script>
</body>
</html>